import _ from 'lodash'

export function List(ctx) {
  var list = [{
    field: 'date',
    width: '15%'
  }, {
    field: 'op',
    width: '15%'
  }, {
    field: 'action',
    width: 'auto'
  }, {
    field: 'result',
    width: '10%'
  }, {
    field: 'code',
    width: 'auto'
  }]

  _.forEach(list, (item) => {
    let keypath = 'list.' + item.field
    item.name = ctx.$t(keypath)
  })

  return list 
}